package com.yanmaohu.yulia.bean;

import com.yanmaohu.yulia.statement.SqlSchemaManipulationStatement;

/**
 * @author Bright Lee
 */
public final class AlterTransformStatement implements SqlSchemaManipulationStatement {

    private int beginIndex;
    private int endIndex;
    private boolean transform;
    private boolean transforms;
    private SchemaQualifiedName schemaResolvedUserDefinedTypeName;
    private AlterGroupList alterGroupList;

    public AlterTransformStatement(int beginIndex,
                                   boolean transform,
                                   boolean transforms,
                                   SchemaQualifiedName schemaResolvedUserDefinedTypeName,
                                   AlterGroupList alterGroupList) {
        this.beginIndex = beginIndex;
        this.endIndex = alterGroupList.getEndIndex();
        this.transform = transform;
        this.transforms = transforms;
        this.schemaResolvedUserDefinedTypeName = schemaResolvedUserDefinedTypeName;
        this.alterGroupList = alterGroupList;
    }

    @Override
    public int getBeginIndex() {
        return beginIndex;
    }

    @Override
    public int getEndIndex() {
        return endIndex;
    }

    public boolean isTransform() {
        return transform;
    }

    public boolean isTransforms() {
        return transforms;
    }

    public SchemaQualifiedName getSchemaResolvedUserDefinedTypeName() {
        return schemaResolvedUserDefinedTypeName;
    }

    public AlterGroupList getAlterGroupList() {
        return alterGroupList;
    }

}
